Skip to content

Conversation

@petertodd
Copy link
Contributor

Also, how do I get the doc-tests to actually test this example?

Copy link
Collaborator

@Kixunil Kixunil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 7b7085f

@Kixunil
Copy link
Collaborator

Kixunil commented Mar 19, 2025

I suspect that rust after the triple backticks is interfering with running the tests. IIRC I've seen something like that elsewhere.

@tcharding
Copy link
Member

cargo test --doc --all-features seems to run that code. I threw a panic in there to check it was run.

@petertodd
Copy link
Contributor Author

cargo test --doc --all-features seems to run that code. I threw a panic in there to check it was run.

Thanks! That does seem to run the test. Though it actually passes without my change; I guess the test must import rand some other way.

@tcharding
Copy link
Member

tcharding commented Mar 20, 2025

Oh rand is a dependency so its available without importing. Sorry I didn't look closer. Our CI would have to be broken if this code didn't work already.

@Kixunil
Copy link
Collaborator

Kixunil commented Mar 20, 2025

Regarding the wasm failure, how come it broke now and not before? Looks like we're missing a pin somewhere but also the code needs to be fixed (possibly also in upstream).

@apoelstra
Copy link
Member

@Kixunil wasm has been broken for months and months.

Lol @ "missing a pin". Good luck pinning anything in wasm. See my nearly-two-year-old "you can't pin anything" issue drager/wasm-pack#1316

Copy link
Member

@apoelstra apoelstra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 7b7085f; successfully ran local tests

@Kixunil
Copy link
Collaborator

Kixunil commented Mar 21, 2025

@apoelstra clearly, this is some sort of compiler thing (though might be the cc crate). Anyway, that issue is actually very concerning to me for other reasons, so I'm going to check if I can fix it.

@Kixunil
Copy link
Collaborator

Kixunil commented Mar 21, 2025

Oh, it looks like build should work, it's just install that doesn't.

@apoelstra apoelstra merged commit 442de10 into rust-bitcoin:master Mar 21, 2025
29 of 30 checks passed
chain-forgexcr45 added a commit to chain-forgexcr45/rust-secp256k1 that referenced this pull request Sep 28, 2025
…oc example

7b7085f5afe28357134f68ccc85500eb317fa522 Minor: fix missing import in doc example (Peter Todd)

Pull request description:

  Also, how do I get the doc-tests to actually test this example?

ACKs for top commit:
  Kixunil:
    ACK 7b7085f5afe28357134f68ccc85500eb317fa522
  apoelstra:
    ACK 7b7085f5afe28357134f68ccc85500eb317fa522; successfully ran local tests

Tree-SHA512: 21b839122f450cd4eea09bc4119e2f89ae31af7a6ebf8f732a06f7ad773f18fc975027a1508d1ba671cea8b414be8b10b79316af46fd5df0328d4b26adf2848d
william2332-limf added a commit to william2332-limf/rust-secp256k1 that referenced this pull request Oct 2, 2025
…oc example

7b7085f5afe28357134f68ccc85500eb317fa522 Minor: fix missing import in doc example (Peter Todd)

Pull request description:

  Also, how do I get the doc-tests to actually test this example?

ACKs for top commit:
  Kixunil:
    ACK 7b7085f5afe28357134f68ccc85500eb317fa522
  apoelstra:
    ACK 7b7085f5afe28357134f68ccc85500eb317fa522; successfully ran local tests

Tree-SHA512: 21b839122f450cd4eea09bc4119e2f89ae31af7a6ebf8f732a06f7ad773f18fc975027a1508d1ba671cea8b414be8b10b79316af46fd5df0328d4b26adf2848d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants